package tcts0421;
public class Student extends Person{
    public String sno;

    public Student(String id, String name, String sno) {
        super(id, name);
        this.sno = sno;

    }

    public void study() {
        System.out.println("I am Student,I am studying");
    }

    public void eat() {
        System.out.println("I am Student");
        System.out.println("id:" + id);
        System.out.println("name:" + name);
        System.out.println("sno:" + sno);
        System.out.println("eating ..........");
    }

    public String toString() {
        return "Student " + "ID:" + this.id + " Name:" + this.name + " SNo:" + this.sno;
    }
}